
<link rel="stylesheet" type="text/css" href="../css/themes/default/easyui.css">
<link rel="stylesheet" type="text/css" href="../css/themes/icon.css">
<link rel="stylesheet" type="text/css" href="../css/upload/uploadifive.css">
<link rel="stylesheet" type="text/css" href="../css/upload/uploadify.css">
<div id="div-supply-baseinfo" data-options="border:false">
	
		<div class="well well-small" style="margin-left: 5px;margin-top: 5px">			
			<p>
				<span class="badge">提示</span>
				<font color="red">点击 供应商分类</font><span class="label-info"></span> 可以对相应分类的供应商进行编辑!
			</p>
		</div>
		<table cellpadding="2" cellspacing="2" style="width:100%">
			<tr>
				<td style="width:20%">
				
					<div class="doc-type">
						<table cellpadding="0" cellspacing="0" >
							<tr>
								<td style="padding-left:4px;padding-bottom:4px;" class="doc-type-list-btn">
									
										
								</td>						
								
							</tr>
						</table>
					</div>				
					
					
					<table class="dg-type easyui-treegrid" title="供应商分类"
						data-options="rownumbers:true,
						animate: true,									
						striped:true,
						border:true,
						//singleSelect:false,
						idField: 'id',
						treeField: 'name',					
						fitColumns: true,
						checkOnSelect:true,
						pagination : true,
						selectOnCheck:true">
						
						<thead>						
							<tr>		
								<th field="name" width="100" align="left" halign="center">分类名称</th>														
							</tr>
						</thead>
						
					</table>
				</td>
				
				<div class="search-detail">			
					<div name="sup_name_like">单位名称</div>
					<div name="authorizedperson_like">联系人</div>								
				</div>
				<td style="width:79%">
					<div id="supply-list-panel" class="easyui-panel list-panel toggle-panel" data-options="openAnimation:'slide',closeAnimation:'slide'">
					 <div class="tb-list tb-detail" style="padding:2px 0">
						<table cellpadding="0" cellspacing="0"> 
							<tr>
								<td style="padding-left:2px" class="list-btn">
							
								</td>
								<td style="padding-left:2px" class="search-btn">
									<input class="searchbox searchbox-detail" type="text" style="width:150px;"/>
									<a href="javascript:void(0);" class="easyui-linkbutton conditon-search function-btn"  plain="true" >查询条件</a>
									<a href="javascript:void(0);" class="easyui-linkbutton conditon-search function-btn" iconCls="icon-search" plain="true" >执行查询</a>
								</td>
							</tr>
						</table>
					</div>
					
					<table id="dg-detail" class="easyui-datagrid dg-detail" title="供应商列表"
						data-options="rownumbers:true,
						animate: true,									
						striped:true,
						border:true,
						//singleSelect:false,
						idField: 'id',									
						fitColumns: true,
						checkOnSelect:true,
						pagination : true,
						selectOnCheck:true					
						">
						
						<thead>						
							<tr>
								<th field="ck" checkbox="true" ></th>
								<th field="sup_name" width="100" align="left" halign="center">供应商名称</th>
								<th field="openingbank" width="100" align="left" halign="center">开户银行</th>
								<th field="legalrepresentative" width="40" align="left" halign="center">法定代表人</th>
								<th field="authorizedperson" width="40" align="left" halign="center">联系人</th>
								<th field="contactphone" width="60" align="left" halign="center">联系电话</th>
								<th field="is_used" width="60" align="left" halign="center" data-options="{
									formatter:function(value,row,index){
										if(value && value=='Y'){
											return '启用';
										}else{
											return '未启用';
										}
									},
									styler:function(value,row,index){
										if(value && value=='Y'){
											return 'color:blue';
										}else{
											return 'color:gray';
										}
									}
								}">启用状态</th>
								<!--<th field="filling_time" width="60" align="left" halign="center">建档时间</th>-->
								<th field="status" width="30" align="center" data-options="{
										formatter:function(value,row,index){
											if(value){
												switch(value){
													case '0':
													return '<span><font color=blue>已提交</font></span>';
													break;
													case '1':
													return '<span><font color=green>审核通过</font></span>';
													break;
													case '-1':
													return '<span><font color=red>未通过</font></span>';
													break;
												}
											}
											return null;						
										}
								}">审核状态</th>	
																			
							</tr>
						</thead>
						
					</table>
					</div>
					
					
					<!-- 基本信息-->
					<div id="supply-baseinfo" class="easyui-panel edit-panel toggle-panel" data-options="closed:true,openAnimation:'slide',closeAnimation:'slide',title:'基本信息'">
					
						
							<div style="height:auto;widtd:auto">
								<table>
									<tr>
										<td style="margin-bottom:5px" class="edit-btn">
											
										</td>
										<td>
											<a href="javascript:void(0);" class="easyui-linkbutton function-btn"  iconcls="icon-undo" plain="true" >返回列表</a>											
										</td>
									</tr>
								</table> 		
						    </div>
						    
							<form class="main-form" metdod="post">
								<fieldset>	
									<input name="id" id="id"  type="hidden"/>
									<input name="created" id="created"  type="hidden"/>
									<input name="creater" id="creater"  type="hidden"/>
									<input name="state" id="state"  type="hidden"/>
									<input name="typeId" id="typeId"  type="hidden"/>
									<input name="lobid" id="lobid"  type="hidden"/>
									<input name="integritytypeName" id="integritytypeName"  type="hidden"/>
									 <table>
										 <tr>
										 	
										 	<th>单位名称</th>
											<td><input name="sup_name" id="sup_name" type="text" style="width: 310px;" class="easyui-textbox easyui-validatebox" required="required"/>
											<input name="dwxh" id="dwxh"  type="hidden"/>
											</td>
											<th>法人代表</th>
											<td><input name="legalrepresentative" id="legalrepresentative" style="width: 310px;" class="easyui-textbox easyui-validatebox"  type="text"/></td>						    
										 </tr>
										 <tr>					    
											<th>开户银行</th>
											<td><input id="openingbank" name="openingbank" type="text" style="width: 310px;" class="easyui-textbox easyui-validatebox"  required="required" /></td>
											<th>账号</th>
											<td><input id="numbeaccount" name="numbeaccount" type="text" style="width: 310px;" class="easyui-textbox easyui-validatebox"  required="required" /></td>
											
											
										 </tr>
										 
										 
										 <tr>
										 	<th>联系人姓名</th>
											<td><input name="authorizedperson" id="authorizedperson" style="width: 310px;" class="easyui-textbox easyui-validatebox"  type="text"/></td>
										 	<th>身份证号码</th>
											<td><input name="identitycard" id="identitycard" type="text" style="width: 310px;" class="easyui-textbox easyui-validatebox" required="required"/></td>						    
										 </tr>
										 <tr>					    
											<th>联系电话</th>
											<td><input id="contactphone" name="contactphone" type="text" style="width: 310px;" class="easyui-textbox easyui-validatebox"  required="required" /></td>
										
											<th>供应商分类</th>
											<td>
											<input name="integritytype" id="integritytype" type="text" style="width: 310px;" class="easyui-textbox easyui-validatebox" />
											<input name="sup_type" id="sup_type" type="hidden" />
											</td>
										 </tr>
										 
										 <tr>	
											<th>排序编号</th>
											<td><input name="sortedid" id="sortedid" type="text" style="width: 310px;" class="easyui-textbox easyui-validatebox" /></td>
											<th>登记时间</th>
											<td><input name="register_time" id="register_time" type="text" style="width: 310px;" class="easyui-datebox easyui-validatebox" /></td>
										 </tr>				 
										 
										  <tr>	 	
											<th>是否启用</th>
											<td>
												<select id="is_used" class="easyui-combobox" name="is_used" style="width:120px;" data-options="required:true">
													<option value="Y">是</option>
													<option value="N">否</option>
												</select></td>
											<tr>  
											<th>备注</th>
											<td colspan="3"><input id="remarks" name="remarks"  class="easyui-textbox easyui-validatebox" style="width: 710px;height: 100px" data-options="multiline:true"/></td>
										</tr>			 
										
									 </table>
								</fieldset>
							</form>						
					</div>
					
										
					<!-- 附件 panel -->
					<div id="supply-archive" class="easyui-panel upload-panel toggle-panel" data-options="closed:true,openAnimation:'slide',closeAnimation:'slide'">
						<div class="archive-btn">
							<a href="javascript:void(0);" class="easyui-linkbutton file_upload_btn" iconcls="icon-add" plain="true">上传</a>
							<a href="javascript:void(0);" class="easyui-linkbutton file_upload_btn" iconcls="icon-remove" plain="true">删除</a>
							<a href="javascript:void(0);" class="easyui-linkbutton file_upload_btn" iconcls="icon-undo" plain="true">返回列表</a>
					    </div>
						<div class="table-archive"/>
						<form class="upload-form">
							<div id="queue"></div>
							<input id="file_upload" name="file_upload" type="file" multiple="true">
							
						</form>
					</div>
					<!-- 不良记录-->
					<div id="supply-badinfomation" class="easyui-panel edit-panel toggle-panel" data-options="closed:true,openAnimation:'slide',closeAnimation:'slide'">
					</div>
				</td>
			</tr>		
		</div>
	
	
	
	
	
	
</div>


<script>

requirejs(['typeListPage','supplyEditPage','domReady!'],function(typeListPage,supplyEditPage,doc){
	typeListPage.init({
		doc:doc,		
		rootId:'div-supply-baseinfo',
		edit_window:'supply-archive',
		moduleCode:'supplyBaseinfo',
		subSystemCode:'supply',
		buttonExtends:supplyEditPage.buttonExtends,
		typeCode:'supplyBasetype',
		typeField:'integritytype',		
		queryParam:{id:''}
	});	
});	

</script>
